<option value="0" selected>All</option>
<%								  
    rs = task.getContractRefList();
	int id = 0;
	String Colour="";
	float pending = 0;
	float unfixed = 0;	
    while (rs.next())
	{
		id = rs.getInt("id");
		pending = rs.getFloat("Tons")-rs.getFloat("receive_tons");
		unfixed = rs.getFloat("unfixed_tons");
		if ((pending > 0) && (unfixed > 0)) Colour = "#FF0000";
		if ((pending == 0) && (unfixed > 0)) Colour = "#FFFF66";
		if ((pending > 0) && (unfixed == 0)) Colour = "#33CCFF";		
%>		
		<option value="<%=id%>" style="color:<%=Colour%>"><%=rs.getString("ref_number")%></option>
<%
	}
	task.getResponse().setSelected("contracts",focused_id);
	//task.getResponse().setSelected("contracts");
	rs.close();
%>	
